feat(ascend): add support for DDie type in device detection and update related logic - #21
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the Ascend detector runtime to support the DDie (DCMI_DIE_TYPE_DDIE) query for A5/950 generation chips, replacing the previous NDIE query. It also consolidates various Ascend 950 variants (such as Ascend950PR and Ascend950DT) to collapse onto a single 'Ascend950' SoC representation, and adds support for resolving these names when they do not pass through the detector directly. I have no feedback to provide as there are no review comments to assess.
There was a problem hiding this comment.
Pull request overview
Adds Ascend A5/950-series detection updates by introducing the DDie identifier type for DCMI v2 die reads and normalizing 950-series naming so variants (e.g., 950PR, 950DT, die-suffixed SOC_VERSION) resolve consistently to the Ascend950 generation for CANN variant selection.
Changes:
- Add
DCMI_DIE_TYPE_DDIEconstant to the localpydcmibinding and switch die-ID probing order toVDIE -> DDIEfor DCMI v2. - Collapse
Ascend950*suffix variants toAscend950in SoC-name guessing and inget_ascend_soc_version()fallback logic (so stored/configured legacy names still map to the right CANN variant). - Update and extend tests to validate the new DDie fallback and the expanded 950-name resolution behavior.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
tests/gpustack_runtime/detector/test_ascend.py |
Updates expected A5/950 arch_family normalization to Ascend950, adds tests ensuring legacy/stored 950 names still resolve to variant 950, and validates DDIE die-id fallback in v2 detection. |
gpustack_runtime/detector/pydcmi/__init__.py |
Introduces the DCMI_DIE_TYPE_DDIE enum constant used by v2 die-ID probing. |
gpustack_runtime/detector/ascend.py |
Switches v2 die-ID probing to use DDIE, extends SoC version resolution to treat any Ascend950* as Ascend950, and updates the SoC mapping accordingly. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
gpustack/gpustack#6148